<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
	xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
	<modelVersion>4.0.0</modelVersion>
	<groupId>msr-ws</groupId>
	<artifactId>msr-ws</artifactId>
	<version>0.0.1-SNAPSHOT</version>
	<packaging>war</packaging>

	<properties>
		<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
		<spring.version>3.0.0.RELEASE</spring.version>
		<hadoop.version>1.1.2</hadoop.version>
		<hbase.version>0.94.10</hbase.version>
		<slf.version>1.5.8</slf.version>
	</properties>

	<dependencies>

		<dependency>
			<groupId>org.nuiton.thirdparty</groupId>
			<artifactId>REngine</artifactId>
			<version>0.6-1</version>
		</dependency>
		<dependency>
			<groupId>org.nuiton.thirdparty</groupId>
			<artifactId>Rserve</artifactId>
			<version>0.6-1</version>
		</dependency>

		<dependency>
			<groupId>org.apache.hbase</groupId>
			<artifactId>hbase</artifactId>
			<version>${hbase.version}</version>
			<exclusions>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>servlet-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jetty</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jetty-util</artifactId>
					<!-- <version>1.4</version> -->
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jsp-2.1</artifactId>
					<!-- <version>6.1.14</version> -->
				</exclusion>
				<exclusion>
					<groupId>org.apache.thrift</groupId>
					<artifactId>thrift</artifactId>
				</exclusion>
				<exclusion>
					<groupId>com.google.guava</groupId>
					<artifactId>guava</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.jruby</groupId>
					<artifactId>jruby-complete</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jsp-api-2.1</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>servlet-api-2.5</artifactId>
				</exclusion>
				<exclusion>
					<groupId>commons-httpclient</groupId>
					<artifactId>commons-httpclient</artifactId>
				</exclusion>
				<!-- <exclusion> -->
				<!-- <groupId>commons-lang</groupId> -->
				<!-- <artifactId>commons-lang</artifactId> -->
				<!-- </exclusion> -->
				<exclusion>
					<groupId>org.apache.hadoop</groupId>
					<artifactId>avro</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jsp-2.1</artifactId>
				</exclusion>
				<exclusion>
					<groupId>tomcat</groupId>
					<artifactId>jasper-compiler</artifactId>
				</exclusion>
				<exclusion>
					<groupId>tomcat</groupId>
					<artifactId>jasper-runtime</artifactId>
				</exclusion>
				<!-- <exclusion> -->
				<!-- <groupId>com.google.protobuf</groupId> -->
				<!-- <artifactId>protobuf-java</artifactId> -->
				<!-- </exclusion> -->

				<exclusion>
					<groupId>javax.servlet</groupId>
					<artifactId>servlet-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>log4j</groupId>
					<artifactId>log4j</artifactId>
				</exclusion>

				<exclusion>
					<artifactId>jersey-core</artifactId>
					<groupId>com.sun.jersey</groupId>
				</exclusion>
				<exclusion>
					<artifactId>jersey-json</artifactId>
					<groupId>com.sun.jersey</groupId>
				</exclusion>
				<exclusion>
					<artifactId>jersey-server</artifactId>
					<groupId>com.sun.jersey</groupId>
				</exclusion>
				<exclusion>
					<groupId>org.codehaus.jackson</groupId>
					<artifactId>jackson-mapper-asl</artifactId>
				</exclusion>
			</exclusions>
		</dependency>
		<dependency>
			<groupId>org.apache.hadoop</groupId>
			<artifactId>hadoop-core</artifactId>
			<version>${hadoop.version}</version>

			<exclusions>
				<exclusion>
					<groupId>org.codehaus.jackson</groupId>
					<artifactId>jackson-mapper-asl</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>servlet-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jetty</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jetty-util</artifactId>
					<!-- <version>1.4</version> -->
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jsp-2.1</artifactId>
					<!-- <version>6.1.14</version> -->
				</exclusion>
				<exclusion>
					<groupId>org.apache.thrift</groupId>
					<artifactId>thrift</artifactId>
				</exclusion>
				<exclusion>
					<groupId>com.google.guava</groupId>
					<artifactId>guava</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.jruby</groupId>
					<artifactId>jruby-complete</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jsp-api-2.1</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>servlet-api-2.5</artifactId>
				</exclusion>
				<exclusion>
					<groupId>commons-httpclient</groupId>
					<artifactId>commons-httpclient</artifactId>
				</exclusion>
				<exclusion>
					<groupId>commons-lang</groupId>
					<artifactId>commons-lang</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.apache.hadoop</groupId>
					<artifactId>avro</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.mortbay.jetty</groupId>
					<artifactId>jsp-2.1</artifactId>
				</exclusion>
				<exclusion>
					<groupId>tomcat</groupId>
					<artifactId>jasper-compiler</artifactId>
				</exclusion>
				<exclusion>
					<groupId>tomcat</groupId>
					<artifactId>jasper-runtime</artifactId>
				</exclusion>
				<exclusion>
					<groupId>com.google.protobuf</groupId>
					<artifactId>protobuf-java</artifactId>
				</exclusion>

				<exclusion>
					<groupId>javax.servlet</groupId>
					<artifactId>servlet-api</artifactId>
				</exclusion>
				<exclusion>
					<groupId>log4j</groupId>
					<artifactId>log4j</artifactId>
				</exclusion>

				<exclusion>
					<artifactId>jersey-core</artifactId>
					<groupId>com.sun.jersey</groupId>
				</exclusion>
				<exclusion>
					<artifactId>jersey-json</artifactId>
					<groupId>com.sun.jersey</groupId>
				</exclusion>
				<exclusion>
					<artifactId>jersey-server</artifactId>
					<groupId>com.sun.jersey</groupId>
				</exclusion>
			</exclusions>

			<!-- <exclusions> -->

			<!-- <exclusion> <artifactId>jersey-core</artifactId> <groupId>com.sun.jersey</groupId> 
				</exclusion> -->
			<!-- <exclusion> <artifactId>jersey-json</artifactId> <groupId>com.sun.jersey</groupId> 
				</exclusion> -->
			<!-- <exclusion> <artifactId>jersey-server</artifactId> <groupId>com.sun.jersey</groupId> 
				</exclusion> -->



			<!-- <exclusion> -->
			<!-- <groupId>org.mortbay.jetty</groupId> -->
			<!-- <artifactId>jetty</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>org.mortbay.jetty</groupId> -->
			<!-- <artifactId>jetty-util</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>org.mortbay.jetty</groupId> -->
			<!-- <artifactId>jsp-2.1</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>org.mortbay.jetty</groupId> -->
			<!-- <artifactId>jsp-api-2.1</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>org.mortbay.jetty</groupId> -->
			<!-- <artifactId>servlet-api-2.1</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>javax.servlet</groupId> -->
			<!-- <artifactId>servlet-api</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>javax.servlet.jsp</groupId> -->
			<!-- <artifactId>jsp-api</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>tomcat</groupId> -->
			<!-- <artifactId>jasper-compiler</artifactId> -->
			<!-- </exclusion> -->
			<!-- <exclusion> -->
			<!-- <groupId>tomcat</groupId> -->
			<!-- <artifactId>jasper-runtime</artifactId> -->
			<!-- </exclusion> -->
			<!-- </exclusions> -->
		</dependency>
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-log4j12</artifactId>
			<version>${slf.version}</version>
		</dependency>
		<dependency>
			<groupId>org.slf4j</groupId>
			<artifactId>slf4j-api</artifactId>
			<version>${slf.version}</version>
		</dependency>

		<!-- To resolve eclipse problem:Failed to read artifact descriptor for 
			org.apache.maven.plugins:maven-resources-plugin:jar:2.4.3 -->
		<!-- <dependency> -->
		<!-- <groupId>org.apache.maven.plugins</groupId> -->
		<!-- <artifactId>maven-resources-plugin</artifactId> -->
		<!-- <version>2.4.3</version> -->
		<!-- </dependency> -->

		<!-- Spring dependencies -->
		<dependency>
			<groupId>org.springframework.security</groupId>
			<artifactId>spring-security-core</artifactId>
			<version>${spring.version}</version>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-context</artifactId>
			<version>${spring.version}</version>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-web</artifactId>
			<version>${spring.version}</version>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-beans</artifactId>
			<version>${spring.version}</version>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-test</artifactId>
			<version>${spring.version}</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-webmvc</artifactId>
			<version>${spring.version}</version>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-core</artifactId>
			<version>3.0.5.RELEASE</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-jdbc</artifactId>
			<version>3.0.5.RELEASE</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>org.apache.commons</groupId>
			<artifactId>commons-lang3</artifactId>
			<version>3.1</version>
		</dependency>

		<dependency>
			<groupId>org.apache.tomcat</groupId>
			<artifactId>tomcat-jdbc</artifactId>
			<version>7.0.21</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>org.apache.tomcat</groupId>
			<artifactId>tomcat-juli</artifactId>
			<version>7.0.8</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-tx</artifactId>
			<version>3.0.5.RELEASE</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>org.springframework</groupId>
			<artifactId>spring-test</artifactId>
			<version>3.0.6.RELEASE</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>net.sourceforge.jtds</groupId>
			<artifactId>jtds</artifactId>
			<version>1.2.4</version>
			<type>jar</type>
			<optional>false</optional>
		</dependency>

		<dependency>
			<groupId>cglib</groupId>
			<artifactId>cglib</artifactId>
			<version>2.2.2</version>
		</dependency>

		<dependency>
			<groupId>javax.servlet</groupId>
			<artifactId>jstl</artifactId>
			<version>1.2</version>
			<scope>provided</scope>
		</dependency>

		<dependency>
			<groupId>javax.servlet</groupId>
			<artifactId>servlet-api</artifactId>
			<version>2.5</version>
			<scope>provided</scope>
		</dependency>


		<dependency>
			<groupId>commons-codec</groupId>
			<artifactId>commons-codec</artifactId>
			<version>1.3</version>
		</dependency>

		<dependency>
			<groupId>org.codehaus.jackson</groupId>
			<artifactId>jackson-mapper-asl</artifactId>
			<!-- <version>1.9.2</version> -->
			<version>1.7.1</version>
		</dependency>

		<dependency>
			<groupId>org.powermock</groupId>
			<artifactId>powermock-module-junit4</artifactId>
			<version>1.4.10</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.powermock</groupId>
			<artifactId>powermock-api-mockito</artifactId>
			<version>1.4.10</version>
			<scope>test</scope>
		</dependency>

		<dependency>
			<groupId>org.mockito</groupId>
			<artifactId>mockito-core</artifactId>
			<version>1.9.0</version>
			<scope>test</scope>
			<exclusions>
				<exclusion>
					<artifactId>hamcrest-core</artifactId>
					<groupId>org.hamcrest</groupId>
				</exclusion>
			</exclusions>
		</dependency>

		<!-- Jersey dependencies -->
		<dependency>
			<groupId>com.sun.jersey</groupId>
			<artifactId>jersey-bundle</artifactId>
			<version>1.8</version>
			<!-- <scope>compile</scope> -->
		</dependency>
		<dependency>
			<groupId>com.sun.jersey</groupId>
			<artifactId>jersey-server</artifactId>
			<version>1.8</version>
			<!-- <scope>compile</scope> -->
		</dependency>
		<!-- <dependency> <groupId>com.sun.jersey</groupId> <artifactId>jersey-client</artifactId> 
			<version>1.1.5</version> <scope>compile</scope> <exclusions> <exclusion> 
			<artifactId>jersey-core</artifactId> <groupId>com.sun.jersey</groupId> </exclusion> 
			</exclusions> </dependency> <dependency> <groupId>javax.ws.rs</groupId> <artifactId>jsr311-api</artifactId> 
			<version>1.0</version> </dependency> <dependency> <groupId>com.sun.jersey</groupId> 
			<artifactId>jersey-json</artifactId> <version>1.5</version> <exclusions> 
			<exclusion> <artifactId>jersey-core</artifactId> <groupId>com.sun.jersey</groupId> 
			</exclusion> </exclusions> </dependency> -->

		<dependency>
			<groupId>com.sun.jersey.contribs</groupId>
			<artifactId>jersey-spring</artifactId>
			<version>1.8</version>
			<exclusions>
				<exclusion>
					<groupId>org.springframework</groupId>
					<artifactId>spring</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.springframework</groupId>
					<artifactId>spring-core</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.springframework</groupId>
					<artifactId>spring-web</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.springframework</groupId>
					<artifactId>spring-beans</artifactId>
				</exclusion>
				<exclusion>
					<groupId>org.springframework</groupId>
					<artifactId>spring-context</artifactId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>com.sun.jersey.contribs</groupId>
			<artifactId>jersey-multipart</artifactId>
			<version>1.8</version>
		</dependency>

		<dependency>
			<groupId>com.sun.jersey</groupId>
			<artifactId>jersey-json</artifactId>
			<version>1.8</version>
			<exclusions>
				<exclusion>
					<groupId>org.codehaus.jackson</groupId>
					<artifactId>jackson-mapper-asl</artifactId>
				</exclusion>
			</exclusions>
		</dependency>

		<dependency>
			<groupId>org.codehaus.jackson</groupId>
			<artifactId>jackson-mapper-asl</artifactId>
			<version>1.8.8</version>
		</dependency>


		<!-- Rest Assured Service Test -->
		<dependency>
			<groupId>com.jayway.restassured</groupId>
			<artifactId>rest-assured</artifactId>
			<version>1.6.2</version>
			<scope>test</scope>
		</dependency>

		<!-- mysql driver -->
		<dependency>
			<groupId>mysql</groupId>
			<artifactId>mysql-connector-java</artifactId>
			<version>5.1.6</version>
		</dependency>

		<!-- Log4j -->
		<dependency>
			<groupId>log4j</groupId>
			<artifactId>log4j</artifactId>
			<version>1.2.16</version>
		</dependency>
	</dependencies>

	<build>
		<finalName>msr-ws</finalName>
		<plugins>
			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-surefire-plugin</artifactId>
				<version>2.12</version>
				<dependencies>
					<dependency>
						<groupId>org.apache.maven.surefire</groupId>
						<artifactId>surefire-junit47</artifactId>
						<version>2.12</version>
					</dependency>
				</dependencies>
				<configuration>
					<includes>
						<include>**/*.class</include>
					</includes>
					<excludedGroups>com.aad.ws.resource.IntegrationTest
					</excludedGroups>
				</configuration>
			</plugin>

			<plugin>
				<groupId>org.apache.maven.plugins</groupId>
				<artifactId>maven-failsafe-plugin</artifactId>
				<dependencies>
					<dependency>
						<groupId>org.apache.maven.surefire</groupId>
						<artifactId>surefire-junit47</artifactId>
						<version>2.12</version>
					</dependency>
				</dependencies>
				<configuration>
					<groups>com.aad.ws.resource.IntegrationTest</groups>
				</configuration>
				<executions>
					<execution>
						<goals>
							<goal>integration-test</goal>
						</goals>
						<configuration>
							<includes>
								<include>**/*.class</include>
							</includes>
						</configuration>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.codehaus.cargo</groupId>
				<artifactId>cargo-maven2-plugin</artifactId>
				<version>1.1.4</version>
				<configuration>
					<wait>false</wait>
					<container>
						<containerId>tomcat6x</containerId>
						<timeout>300000</timeout>
						<zipUrlInstaller>
							<url>http://archive.apache.org/dist/tomcat/tomcat-6/v6.0.8/bin/apache-tomcat-6.0.8.zip
							</url>
							<downloadDir>${project.build.directory}/downloads</downloadDir>
							<extractDir>${project.build.directory}/extracts</extractDir>
						</zipUrlInstaller>
					</container>

					<configuration>
						<type>standalone</type>
						<home>target/tomcat6x/tom</home>
						<properties>
							<cargo.jvmargs>
								-XX:PermSize=256m -XX:MaxPermSize=512m
								-XX:+UseConcMarkSweepGC
								-XX:+CMSClassUnloadingEnabled
								-Daad.ws.log.level.file=DEBUG
								-Daad.ws.log.level.console=DEBUG
								<!---Dtr.log.dir=/Volumes/Work/logs/ -->
							</cargo.jvmargs>
							<cargo.servlet.port>9999</cargo.servlet.port>
							<cargo.tomcat.ajp.port>9999</cargo.tomcat.ajp.port>
						</properties>
					</configuration>

				</configuration>

				<executions>
					<execution>
						<id>start-container</id>
						<phase>pre-integration-test</phase>
						<goals>
							<goal>start</goal>
						</goals>
					</execution>
					<execution>
						<id>stop-container</id>
						<phase>post-integration-test</phase>
						<goals>
							<goal>stop</goal>
						</goals>
					</execution>
				</executions>
			</plugin>

			<plugin>
				<groupId>org.apache.tomcat.maven</groupId>
				<artifactId>tomcat6-maven-plugin</artifactId>
				<version>2.0-beta-1</version>
				<configuration>
					<port>9999</port>
					<path>/msr-ws</path>
					<addContextWarDependencies>true</addContextWarDependencies>
				</configuration>
			</plugin>
		</plugins>
	</build>
</project>